package com.graduation.check.mapper;

import com.graduation.check.entity.User;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Optional;

@Mapper
public interface UserMapper {

    User findByAccount(@Param("account") String account);

    User findByEmail(@Param("email") String email);

    User findById(@Param("id") Long id);

    void insert(User user);

    void update(User user);

    void deleteById(@Param("id") Long id);

    List<User> findAllStudents();

    List<User> findAllTeachers();
}